﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using QLVatTu.Class;

namespace QLVatTu
{
    class HangSo
    {
        public static KetNoiDB cn = new KetNoiDB();

        public static bool DaKetNoiCSDL = false;

        public static string TenDangNhap = "";
        public static string MaQuyenHan = "";
        public static string TenQuyenHan = "";
        public static string TenNguoiDung = "";

        public static void Luu_Hanh_Dong(string TenDangNhap, string TenQuyenHan, string TenNguoiDung, string HanhDong)
        {
            string time = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
            cn.KetNoi();
            cn.Insert_Table("tbl_LicHSuHeThong", " TenDangNhap, TenQuyenHan, TenNguoiDung, HanhDong, ThoiGian", "N'" + TenDangNhap +
                    "',N'" + TenQuyenHan + "',N'" + TenNguoiDung + "',N'" + HanhDong + "','" + time + "'");
        }
    }
}
